﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.Input;
using LeapLibrary;
using Leap;

namespace TronLeapRacing
{
    /*
     * 
     * 
     */

    class Tutorial
    {
        //Timerzeit
        const float TIMER = 3;

        //Contentmanager
        ContentManager Content;

        //Texturen (Buttons, Cursor, Background)
        Texture2D background;

        //Hintergrundbild position
        Vector2 bgPosition = new Vector2(0, 0);

        //Game Infos
        Game1 g1ref;

        //Konstruktor
        public Tutorial(Game1 g1ref)
        {
            this.g1ref = g1ref;
        }

        //Texturen werden aus der Conetentpipeline geladen
        public void LoadContent(ContentManager Content)
        {
            this.Content = Content;
            background = Content.Load<Texture2D>("Background/Tutorial");
        }

        //Position der Hand wird abgefragt und Fullanimation wird geladen
        public void Update(Control control, GameTime gameTime)
        {
            if (control.isSwipe())
                g1ref.setGamestate("play");
        }

        public void Draw(SpriteBatch spriteBatch)
        {
            spriteBatch.Begin();
            spriteBatch.Draw(background, bgPosition, Color.White);
            spriteBatch.End();
        }
    }
}
